<!DOCTYPE html>
<html>
<head>
    <title>数据交换</title>
	<#include "/header.html">
</head>
<body>
<div id="rrapp" v-cloak>
    <div v-show="showList">
        <div class="grid-btn">
            <div class="form-group col-sm-5">
                <template>
                    <div class="block" >
                        <el-date-picker
                                v-model="queryByDate"
                                type="daterange"
                                value-format="yyyy-MM-dd"
                                unlink-panels
                                start-placeholder="开始日期"
                                end-placeholder="结束日期">
                        </el-date-picker>
                    </div>
                </template>
            </div>
            <a class="btn btn-default" @click="query">查询</a>
            <a class="btn btn-primary" @click="openDialog">&nbsp;保存信息到数据库</a>
            <el-dialog title="数据库连接信息" :visible.sync="dialogFormVisible">
                <el-form >
                    <el-form-item label="ip地址" :label-width="formLabelWidth">
                        <el-input v-model="dbConnect.ip"></el-input>
                    </el-form-item>
                    <el-form-item label="数据库类型" :label-width="formLabelWidth">
                        <el-select v-model="dbConnect.dbType" placeholder="请选择">
                            <el-option
                                    v-for="item in dataType"
                                    :key="item.value"
                                    :label="item.label"
                                    :value="item.value">
                            </el-option>
                        </el-select>
                    </el-form-item>
                    <el-form-item label="用户名" :label-width="formLabelWidth">
                        <el-input v-model="dbConnect.root"></el-input>
                    </el-form-item>
                    <el-form-item label="密码" :label-width="formLabelWidth">
                        <el-input type="password" v-model="dbConnect.password"></el-input>
                    </el-form-item>
                </el-form>
                <div slot="footer" class="dialog-footer">
                    <el-button @click="dialogFormVisible = false">取 消</el-button>
                    <el-button type="primary" @click="saveDataToDB">确 定</el-button>
                </div>
            </el-dialog>
            <a class="btn btn-primary" @click="saveToMq">保存到消息队列</a>
        </div>
        <table id="jqGrid"></table>
        <div id="jqGridPager"></div>
    </div>
</div>
<script src="${request.contextPath}/statics/js/modules/function/emp_data_switch.js?_${.now?long}"></script>
</body>
</html>